package com.neusoft.neuiotms.dcam.workflow.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.neusoft.bizcore.activiti.service.ProcessInstanceService;
import com.neusoft.bizcore.auth.common.bean.UserBean;
import com.neusoft.neuiotms.dcam.workflow.dto.ITSMApproveDTO;
import com.neusoft.neuiotms.dcam.workflow.service.ConfirmKJService;

@Service
public class ConfirmKJServiceImpl implements ConfirmKJService {

    @Autowired
    private ProcessInstanceService processInstanceService;

    @Override
    public ITSMApproveDTO confirm(final ITSMApproveDTO dto, final UserBean user) {
        // 完成当前节点
        this.processInstanceService.complete(dto.getWorkOrderNum(), dto.getTaskId(), user);
        return dto;
    }

}
